package com.hqyj.controller;


import com.hqyj.pojo.ApplicationRecord;
import com.hqyj.pojo.RecruitmentRecords;
import com.hqyj.service.IApplicationRecordService;
import com.hqyj.service.IRecruitmentRecordsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author rock
 * @since 2021-10-25
 */
@RestController
@RequestMapping("/recruitment-records")
public class RecruitmentRecordsController {
    @Autowired
    IRecruitmentRecordsService iRecruitmentRecordsService;

    //加载表格数据
    @RequestMapping("/recruitmentList")
    public HashMap<String,Object> listPage(RecruitmentRecords r){
        return iRecruitmentRecordsService.select(r);
    }
    //修改
    @RequestMapping("/update")
    public HashMap<String,Object>  update(RecruitmentRecords r){
        return iRecruitmentRecordsService.update(r);
    }
    //新增
    @RequestMapping("/add")
    public HashMap<String,Object> add( RecruitmentRecords r){
        return iRecruitmentRecordsService.add(r);
    }

    //删除
    @RequestMapping("/del")
    public HashMap<String,Object> del(Integer id){
        return iRecruitmentRecordsService.del(id);
    }
}

